<template>
<div> <quill-editor ref="myQuillEditor" v-model="notice"></quill-editor>
  <el-button style="float: right;margin-top: 10px" @click="addNotice">发布</el-button>
</div>

</template>

<script>
// require styles 导入富文本编辑器对应的样式
import 'quill/dist/quill.core.css'
import 'quill/dist/quill.snow.css'
import 'quill/dist/quill.bubble.css'
import { quillEditor } from 'vue-quill-editor'
export default {
  components: {
    quillEditor
  },
  name: 'add',
  data () {
    return {
      notice: ''
    }
  },
  methods: {
    // 用于改变面包屑导航栏
    changeBread () {
      document.getElementById('first').innerHTML = '公告管理'
      document.getElementById('second').innerHTML = '发布公告'
      document.getElementById('separate_1').innerHTML = '/'
      document.getElementById('separate_2').innerHTML = '/'
    },
    addNotice () {
      alert(this.notice)
    }
  },
  mounted () {
    this.changeBread()
  }
}
</script>

<style scoped>

</style>
